Skip to content

Conversation

@jpennors
Copy link

@jpennors jpennors commented Jul 7, 2025

Hi 👋

A small PR for an issue I recently got with the SDKError exception class.

Context

To be monitored and processed, exceptions might be mapped as dictionary or set. I recently encounter the following issue using the mistral Python client and Rollbar :

TypeError("unhashable type: 'SDKError'")

This means, I got an exception using the mistral library and I'm not aware of it because the exception is not sent to Rollbar.

Bug reproduction

Just do :

error = SDKError("", 0, "")
print({error})

It will fail. Then add frozen=True like in the PR and it will work well.

Here is where an exception is mapped as a set in Rollbar : https://github.com/rollbar/pyrollbar/blob/84efba4ae3c9a5faef60b3bed3856f27940a0964/rollbar/__init__.py#L817

@GaspardBT
Copy link
Collaborator

Hey 👋
Thanks for opening this PR and the detailed reproduction, those files are auto generated and shouldn't be modified this way.
I will report this issue to our code generation partner to see how we can address this issue.

Could you open an issue with this bug report so we can keep you updated
Thanks

@jpennors
Copy link
Author

jpennors commented Sep 5, 2025

Sorry for the delay @GaspardBT , I created the issue : #272

@jpennors jpennors closed this Sep 5, 2025
@jpennors jpennors deleted the unhashable-sdk-error branch September 5, 2025 16:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants